package yl.hs.bmipfull.pojo.system;

import yl.hs.bmipfull.annotations.DBField;
import yl.hs.bmipfull.annotations.DBTable;
import yl.hs.bmipfull.pojo.BaseEntity;
import yl.hs.bmipfull.pojo.IParent;

import java.util.List;

/**
 * 作用:  行政区域实体类<br/>
 * 创建时间: 2021年05月13日 11时17分29秒 <br/>
 *
 * @author 张凯
 */
@DBTable(disName = "区域信息", mapCode = "sys_area")
public class AreaEntity extends BaseEntity implements IParent {

    /**
     * 主键
     */
    private Long id;
    /**
     * 地区编号
     */
    @DBField(disName = "数据项编号", mapCode = "sn", snPrefix = "AREA", isSerialNumber = true, isRequire = true)
    private String sn;
    /**
     * 地区名称
     */
    @DBField(disName = "地区名称", mapCode = "areaName")
    private String areaName;
    /**
     * 父级编号
     */
    @DBField(disName = "父级代码", mapCode = "parentCode")
    private String parentCode;
    @DBField(disName = "父级编号", mapCode = "parentSN")
    private String parentSN;
    private List<AreaEntity> areaEntityList;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    @Override
    public String getSn() {
        return sn;
    }

    @Override
    public void setSn(String sn) {
        this.sn = sn;
    }

    public String getAreaName() {
        return areaName;
    }

    public void setAreaName(String areaName) {
        this.areaName = areaName;
    }

    @Override
    public String getParentCode() {
        return parentCode;
    }

    @Override
    public void setParentCode(String parentCode) {
        this.parentCode = parentCode;
    }

    @Override
    public int getLayer() {
        return 0;
    }

    @Override
    public void setLayer(int sn) {

    }

    @Override
    public String getParentSN() {
        return parentSN;
    }

    @Override
    public void setParentSN(String parentSN) {
        this.parentSN = parentSN;
    }

    public List<AreaEntity> getAreaEntityList() {
        return areaEntityList;
    }

    public void setAreaEntityList(List<AreaEntity> areaEntityList) {
        this.areaEntityList = areaEntityList;
    }
}